home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacWorld 1998 October
/
Macworld (1998-10).dmg
/
Updaters
/
Curvus Pro
/
Plug-ins
/
Plug-ins factory
/
GenericPlugIn.p
< prev
next >
Wrap
Text File
|
1997-04-27
|
1KB
|
57 lines
UNIT CodeResource;
INTERFACE
USES
OSUtils;
TYPE
plugInParameterNumber=RECORD
realPart,imPart:Double; { Complex number }
END;
plugInParameterArray=ARRAY[0..0] OF plugInParameterNumber;
plugInParameterPtr=^plugInParameterArray;
plugInParameterHandle=^plugInParameterPtr;
trigoMode=(deg,rad,grad);
{$MAIN}
PROCEDURE main(params:plugInParameterHandle;mode:trigoMode);
IMPLEMENTATION
USES
fp;
{ ============================================================================
Main procedure (modify only this procedure !)
params Input parameters (fields 1,2,...)
Result (field 0)
============================================================================ }
PROCEDURE main(params:plugInParameterHandle;mode:trigoMode);
VAR
{ ====================
Variables:
==================== }
sum:Double;
BEGIN
{ ====================
Calculating:
==================== }
{...}
sum:=params^^[1].realPart { real part of the first parameter }
+params^^[2].imPart; { imaginary part of the second parameter }
{ ====================
Result:
==================== }
params^^[0].realPart:=sum;
params^^[0].imPart:=0; { always fill the two field of params^^[0] }
END;
END.